<!DOCTYPE html>
<html lang="en">
<head>
    #include("../include/header.html")
</head>
<body>
<div class="container">
    #include("../include/menu.html")

    <div class="row">
        <div class="col-sm-3"></div>
        <div class="col-sm-6">
            <form class="form-horizontal" id="inputForm" action="${pathPrefix}/form" method="post">
                <input type="hidden" name="id" value="${data.id}"/>

                #call treeSelect("所属接口","interfaceId", "interfaceName",
                "/interface/treeData",data.anInterface.id ?! -1 , data.anInterface.name ?! "")

                #call form_input_text('字段名','name',data.name)

                #call form_input_select('字段类型','dataType',data.dataType,'/field/getFieldDataType')

                #call form_input_text('默认值','defaultValue',data.defaultValue)

                #call form_input_text('描述','description',data.description)

                #call form_input_select('type','type',data.type,'/field/getFieldType')

                <div class="form-group">
                    <div class="col-sm-offset-2 col-sm-10">
                        <div class="checkbox">
                            <label>
                                <input type="checkbox" ${data.required?'checked':''}>是否必填
                            </label>
                        </div>
                    </div>
                </div>

                <div class="form-group">
                    <div class="col-sm-offset-2 col-sm-10">
                        <button type="button" onclick="doSubmit()" class="btn btn-primary">提交</button>
                        <button type="button" onclick="goHistory()" class="btn btn-danger">取消</button>
                    </div>
                </div>
            </form>
        </div>
        <div class="col-sm-3"></div>
    </div>


</div>
#include("../include/footer.html")

</body>

</html>